const TOKEN_KEY = 'token'
// const CHANNEL_KEY = 'news-channel'

export const setToken = token => {
  localStorage.setItem(TOKEN_KEY, JSON.stringify(token))
}

export const getToken = () => {
  return JSON.parse(localStorage.getItem(TOKEN_KEY)) || {}
}

export const removeToken = () => {
  localStorage.removeItem(TOKEN_KEY)
}

// export const setLcoChannel = channel => {
//   localStorage.setItem(CHANNEL_KEY, JSON.stringify(channel))
// }

// export const getLcoChannel = () => {
//   return JSON.parse(localStorage.getItem(CHANNEL_KEY))
// }
